print("Hello world!")
message = "Hello"
print(message)
message = "Hello wrold"
print(message)
name = "ada lovelace"
# title() 首字母大写
print(name.title())
# upper() 全部转大写
print(name.upper())
# lower() 全部转小写
print(name.lower())

first_name = "张"
last_name = "三"

full_name = f"{first_name}{last_name}"  # f 格式化字符串
print(full_name)
# python 3.6之后才能使用f 之前的版本只能使用format
full_name = " {} {} ".format(last_name, last_name)
# \t制表符 \n换行符
print(full_name)
# rstrip() 删除末尾空白字符
print(full_name.rstrip())
# strip() 删除开头空格
print(full_name.strip())

#   练习
ls = "李四"
print(f"Hello {ls} , would you like to learn some Python today?")

some_one = "ray allen"
print(some_one.lower())
print(some_one.upper())
print(some_one.title())

# 2.4 数
result_1 = 2 + 3
print(result_1)
result_1 = 2 - 3
print(result_1)
result_1 = 2 * 3
print(result_1)
result_1 = 2 / 3
print(result_1)
result_1 = 3 ** 2
print(result_1)
result_1 = 0.1 + 0.2
print(result_1)
result_1 = 4 / 2
print(result_1)
result_1 = 12_000_000_000
print(result_1)
# 多个变量同时赋值
x, y, z = 0, 0.1, 5
print(x + y + z)
# 一般用全大小来表示常量
MAX_CONNECTIONS = 5000
